class GoodsDetailBean {
  GoodsBases? goodsBases;
  List<GoodsImages>? goodsImages;
  ShopDetail? shopDetail;
  GdsCommon? gdsCommon;
  Null? commonFormatidBottom;
  Null? commonFormatidTop;

  GoodsDetailBean({this.goodsBases, this.goodsImages, this.shopDetail, this.gdsCommon, this.commonFormatidBottom, this.commonFormatidTop});

  GoodsDetailBean.fromJson(Map<String, dynamic> json) {
    goodsBases = json['goodsBases'] != null ? new GoodsBases.fromJson(json['goodsBases']) : null;
    if (json['goodsImages'] != null) {
      goodsImages = <GoodsImages>[];
      json['goodsImages'].forEach((v) {
        goodsImages!.add(new GoodsImages.fromJson(v));
      });
    }
    shopDetail = json['shopDetail'] != null ? new ShopDetail.fromJson(json['shopDetail']) : null;
    gdsCommon = json['gdsCommon'] != null ? new GdsCommon.fromJson(json['gdsCommon']) : null;
    commonFormatidBottom = json['commonFormatidBottom'];
    commonFormatidTop = json['commonFormatidTop'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    if (this.goodsBases != null) {
      data['goodsBases'] = this.goodsBases!.toJson();
    }
    if (this.goodsImages != null) {
      data['goodsImages'] = this.goodsImages!.map((v) => v.toJson()).toList();
    }
    if (this.shopDetail != null) {
      data['shopDetail'] = this.shopDetail!.toJson();
    }
    if (this.gdsCommon != null) {
      data['gdsCommon'] = this.gdsCommon!.toJson();
    }
    data['commonFormatidBottom'] = this.commonFormatidBottom;
    data['commonFormatidTop'] = this.commonFormatidTop;
    return data;
  }
}

class GoodsBases {
  int? commonId;
  int goodsId=0;
  String goodsName = "";
  String? goodsPromotionTips;
  int? catId;
  int? brandId;
  String? goodsSpec;
  double goodsPrice = 0.0;
  double goodsMarketPrice=0.0;
  int? goodsStock;
  int? goodsAlarm;
  String? goodsCode;
  String? goodsBarcode;
  bool? goodsIsRecommend;
  int? goodsClick;
  int? goodsSalenum;
  int? goodsCollect;
  String goodsImage = "";
  int? goodsEvaluationGoodStar;
  int? goodsEvaluationCount;
  int goodsMaxSale=0;
  int goodsNum=1;
  int? goodsMinSale;
  int? shopId;
  int? goodsIsShelves;
  int? commonVerify;
  int? commonState;
  int? activityStatus;
  ActivityGoodsDetail? activityGoodsDetail;
  double? goodsBabyPrice;
  int? commonType;
  double? commonBabyPrice;
  int? commonLimit;
  int? commonIsTreasure;
  int? type;
  String? commonVideo;
  String? selfGoodsImage;
  String? selfGoodsNameUrl;
  String? loveValueDesc;
  int? commonPaymentMethod;

  GoodsBases(
      {this.commonId,
      this.goodsId=0,
      this.goodsName = "",
      this.goodsPromotionTips,
      this.catId,
      this.brandId,
      this.goodsSpec,
      this.goodsPrice=0.0,
      this.goodsMarketPrice=0.0,
      this.goodsStock,
      this.goodsAlarm,
      this.goodsCode,
      this.goodsBarcode,
      this.goodsIsRecommend,
      this.goodsClick,
      this.goodsSalenum,
      this.goodsCollect,
      this.goodsImage = "",
      this.goodsEvaluationGoodStar,
      this.goodsEvaluationCount,
      this.goodsMaxSale=0,
      this.goodsMinSale,
      this.shopId,
      this.goodsIsShelves,
      this.commonVerify,
      this.commonState,
      this.activityStatus,
      this.activityGoodsDetail,
      this.goodsBabyPrice,
      this.commonType,
      this.commonBabyPrice,
      this.commonLimit,
      this.commonIsTreasure,
      this.type,
      this.commonVideo,
      this.selfGoodsImage,
      this.selfGoodsNameUrl,
      this.loveValueDesc,
      this.commonPaymentMethod});

  GoodsBases.fromJson(Map<String, dynamic> json) {
    commonId = json['commonId'];
    goodsId = json['goodsId'];
    goodsName = json['goodsName'] ?? "";
    goodsPromotionTips = json['goodsPromotionTips'];
    catId = json['catId'];
    brandId = json['brandId'];
    goodsSpec = json['goodsSpec'];
    goodsPrice = json['goodsPrice'];
    goodsMarketPrice = json['goodsMarketPrice'];
    goodsStock = json['goodsStock'];
    goodsAlarm = json['goodsAlarm'];
    goodsCode = json['goodsCode'];
    goodsBarcode = json['goodsBarcode'];
    goodsIsRecommend = json['goodsIsRecommend'];
    goodsClick = json['goodsClick'];
    goodsSalenum = json['goodsSalenum'];
    goodsCollect = json['goodsCollect'];
    goodsImage = json['goodsImage'];
    goodsEvaluationGoodStar = json['goodsEvaluationGoodStar'];
    goodsEvaluationCount = json['goodsEvaluationCount'];
    goodsMaxSale = json['goodsMaxSale'];
    goodsMinSale = json['goodsMinSale'];
    shopId = json['shopId'];
    goodsIsShelves = json['goodsIsShelves'];
    commonVerify = json['commonVerify'];
    commonState = json['commonState'];
    activityStatus = json['activityStatus'];
    activityGoodsDetail = json['activityGoodsDetail'] != null ? new ActivityGoodsDetail.fromJson(json['activityGoodsDetail']) : null;
    goodsBabyPrice = json['goodsBabyPrice'];
    commonType = json['commonType'];
    commonBabyPrice = json['commonBabyPrice'];
    commonLimit = json['commonLimit'];
    commonIsTreasure = json['commonIsTreasure'];
    type = json['type'];
    commonVideo = json['commonVideo'];
    selfGoodsImage = json['selfGoodsImage'];
    selfGoodsNameUrl = json['selfGoodsNameUrl'];
    loveValueDesc = json['loveValueDesc'];
    commonPaymentMethod = json['commonPaymentMethod'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['commonId'] = this.commonId;
    data['goodsId'] = this.goodsId;
    data['goodsName'] = this.goodsName;
    data['goodsPromotionTips'] = this.goodsPromotionTips;
    data['catId'] = this.catId;
    data['brandId'] = this.brandId;
    data['goodsSpec'] = this.goodsSpec;
    data['goodsPrice'] = this.goodsPrice;
    data['goodsMarketPrice'] = this.goodsMarketPrice;
    data['goodsStock'] = this.goodsStock;
    data['goodsAlarm'] = this.goodsAlarm;
    data['goodsCode'] = this.goodsCode;
    data['goodsBarcode'] = this.goodsBarcode;
    data['goodsIsRecommend'] = this.goodsIsRecommend;
    data['goodsClick'] = this.goodsClick;
    data['goodsSalenum'] = this.goodsSalenum;
    data['goodsCollect'] = this.goodsCollect;
    data['goodsImage'] = this.goodsImage;
    data['goodsEvaluationGoodStar'] = this.goodsEvaluationGoodStar;
    data['goodsEvaluationCount'] = this.goodsEvaluationCount;
    data['goodsMaxSale'] = this.goodsMaxSale;
    data['goodsMinSale'] = this.goodsMinSale;
    data['shopId'] = this.shopId;
    data['goodsIsShelves'] = this.goodsIsShelves;
    data['commonVerify'] = this.commonVerify;
    data['commonState'] = this.commonState;
    data['activityStatus'] = this.activityStatus;
    if (this.activityGoodsDetail != null) {
      data['activityGoodsDetail'] = this.activityGoodsDetail!.toJson();
    }
    data['goodsBabyPrice'] = this.goodsBabyPrice;
    data['commonType'] = this.commonType;
    data['commonBabyPrice'] = this.commonBabyPrice;
    data['commonLimit'] = this.commonLimit;
    data['commonIsTreasure'] = this.commonIsTreasure;
    data['type'] = this.type;
    data['commonVideo'] = this.commonVideo;
    data['selfGoodsImage'] = this.selfGoodsImage;
    data['selfGoodsNameUrl'] = this.selfGoodsNameUrl;
    data['loveValueDesc'] = this.loveValueDesc;
    data['commonPaymentMethod'] = this.commonPaymentMethod;
    return data;
  }
}

class ActivityGoodsDetail {
  Null? activityId;
  Null? activityPrice;
  Null? overplusTime;
  Null? goodsUpperLimit;
  Null? goodsLowerLimit;
  Null? goodsBuyCount;
  Null? activityStatus;
  Null? pintuanPrice;
  Null? priceOne;
  Null? markId;
  Null? type;
  Null? goodsStartTime;
  Null? goodsEndTime;
  Null? activityStartStatus;
  Null? goodsPrice;

  ActivityGoodsDetail(
      {this.activityId,
      this.activityPrice,
      this.overplusTime,
      this.goodsUpperLimit,
      this.goodsLowerLimit,
      this.goodsBuyCount,
      this.activityStatus,
      this.pintuanPrice,
      this.priceOne,
      this.markId,
      this.type,
      this.goodsStartTime,
      this.goodsEndTime,
      this.activityStartStatus,
      this.goodsPrice});

  ActivityGoodsDetail.fromJson(Map<String, dynamic> json) {
    activityId = json['activityId'];
    activityPrice = json['activityPrice'];
    overplusTime = json['overplusTime'];
    goodsUpperLimit = json['goodsUpperLimit'];
    goodsLowerLimit = json['goodsLowerLimit'];
    goodsBuyCount = json['goodsBuyCount'];
    activityStatus = json['activityStatus'];
    pintuanPrice = json['pintuanPrice'];
    priceOne = json['priceOne'];
    markId = json['markId'];
    type = json['type'];
    goodsStartTime = json['goodsStartTime'];
    goodsEndTime = json['goodsEndTime'];
    activityStartStatus = json['activityStartStatus'];
    goodsPrice = json['goodsPrice'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['activityId'] = this.activityId;
    data['activityPrice'] = this.activityPrice;
    data['overplusTime'] = this.overplusTime;
    data['goodsUpperLimit'] = this.goodsUpperLimit;
    data['goodsLowerLimit'] = this.goodsLowerLimit;
    data['goodsBuyCount'] = this.goodsBuyCount;
    data['activityStatus'] = this.activityStatus;
    data['pintuanPrice'] = this.pintuanPrice;
    data['priceOne'] = this.priceOne;
    data['markId'] = this.markId;
    data['type'] = this.type;
    data['goodsStartTime'] = this.goodsStartTime;
    data['goodsEndTime'] = this.goodsEndTime;
    data['activityStartStatus'] = this.activityStartStatus;
    data['goodsPrice'] = this.goodsPrice;
    return data;
  }
}

class GoodsImages {
  String imagesImage = "";
  int? imagesDisplayorder;
  int? imagesIsDefault;

  GoodsImages({required this.imagesImage, this.imagesDisplayorder, this.imagesIsDefault});

  GoodsImages.fromJson(Map<String, dynamic> json) {
    imagesImage = json['imagesImage'];
    imagesDisplayorder = json['imagesDisplayorder'];
    imagesIsDefault = json['imagesIsDefault'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['imagesImage'] = this.imagesImage;
    data['imagesDisplayorder'] = this.imagesDisplayorder;
    data['imagesIsDefault'] = this.imagesIsDefault;
    return data;
  }
}

class ShopDetail {
  int? shopId;
  String? shopName;
  String? shopLogo;
  int? shopCount;
  int? shopCollect;
  String? wapShopLogo;
  double? overallScore;
  int? shopInvoices;
  Null? shopTel;
  int? depositStatus;
  bool? shopSelfSupport;
  int? shopIsFarmers;

  ShopDetail(
      {this.shopId,
      this.shopName,
      this.shopLogo,
      this.shopCount,
      this.shopCollect,
      this.wapShopLogo,
      this.overallScore,
      this.shopInvoices,
      this.shopTel,
      this.depositStatus,
      this.shopSelfSupport,
      this.shopIsFarmers});

  ShopDetail.fromJson(Map<String, dynamic> json) {
    shopId = json['shopId'];
    shopName = json['shopName'];
    shopLogo = json['shopLogo'];
    shopCount = json['shopCount'];
    shopCollect = json['shopCollect'];
    wapShopLogo = json['wapShopLogo'];
    overallScore = json['overallScore'];
    shopInvoices = json['shopInvoices'];
    shopTel = json['shopTel'];
    depositStatus = json['depositStatus'];
    shopSelfSupport = json['shopSelfSupport'];
    shopIsFarmers = json['shopIsFarmers'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['shopId'] = this.shopId;
    data['shopName'] = this.shopName;
    data['shopLogo'] = this.shopLogo;
    data['shopCount'] = this.shopCount;
    data['shopCollect'] = this.shopCollect;
    data['wapShopLogo'] = this.wapShopLogo;
    data['overallScore'] = this.overallScore;
    data['shopInvoices'] = this.shopInvoices;
    data['shopTel'] = this.shopTel;
    data['depositStatus'] = this.depositStatus;
    data['shopSelfSupport'] = this.shopSelfSupport;
    data['shopIsFarmers'] = this.shopIsFarmers;
    return data;
  }
}

class GdsCommon {
  String? commonSpecName;
  int? commonId;
  String? commonImage;
  Null? commonFormatidTop;
  Null? commonFormatidBottom;
  List<CommonSpecValueList>? commonSpecValueList;
  int? commonState;
  String? catName;
  int? catId;
  int? commonIsXian;
  int? commonLimit;
  int? commonType;
  double? commonBabyPrice;
  String? cornerUrl = "";
  int? type;
  String? commonVideo;
  String? commonSelfMention;
  Null? commonSpecValue;

  GdsCommon(
      {this.commonSpecName,
      this.commonId,
      this.commonImage,
      this.commonFormatidTop,
      this.commonFormatidBottom,
      this.commonSpecValueList,
      this.commonState,
      this.catName,
      this.catId,
      this.commonIsXian,
      this.commonLimit,
      this.commonType,
      this.commonBabyPrice,
      this.cornerUrl,
      this.type,
      this.commonVideo,
      this.commonSelfMention,
      this.commonSpecValue});

  GdsCommon.fromJson(Map<String, dynamic> json) {
    commonSpecName = json['commonSpecName'];
    commonId = json['commonId'];
    commonImage = json['commonImage'];
    commonFormatidTop = json['commonFormatidTop'];
    commonFormatidBottom = json['commonFormatidBottom'];
    if (json['commonSpecValueList'] != null) {
      commonSpecValueList = <CommonSpecValueList>[];
      json['commonSpecValueList'].forEach((v) {
        commonSpecValueList!.add(new CommonSpecValueList.fromJson(v));
      });
    }
    commonState = json['commonState'];
    catName = json['catName'];
    catId = json['catId'];
    commonIsXian = json['commonIsXian'];
    commonLimit = json['commonLimit'];
    commonType = json['commonType'];
    commonBabyPrice = json['commonBabyPrice'];
    cornerUrl = json['cornerUrl'] ?? "";
    type = json['type'];
    commonVideo = json['commonVideo'];
    commonSelfMention = json['commonSelfMention'];
    commonSpecValue = json['commonSpecValue'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['commonSpecName'] = this.commonSpecName;
    data['commonId'] = this.commonId;
    data['commonImage'] = this.commonImage;
    data['commonFormatidTop'] = this.commonFormatidTop;
    data['commonFormatidBottom'] = this.commonFormatidBottom;
    if (this.commonSpecValueList != null) {
      data['commonSpecValueList'] = this.commonSpecValueList!.map((v) => v.toJson()).toList();
    }
    data['commonState'] = this.commonState;
    data['catName'] = this.catName;
    data['catId'] = this.catId;
    data['commonIsXian'] = this.commonIsXian;
    data['commonLimit'] = this.commonLimit;
    data['commonType'] = this.commonType;
    data['commonBabyPrice'] = this.commonBabyPrice;
    data['cornerUrl'] = this.cornerUrl;
    data['type'] = this.type;
    data['commonVideo'] = this.commonVideo;
    data['commonSelfMention'] = this.commonSelfMention;
    data['commonSpecValue'] = this.commonSpecValue;
    return data;
  }
}

class CommonSpecValueList {
  int? goodsId;
  int? commonId;
  String? goodsSpec;

  CommonSpecValueList({this.goodsId, this.commonId, this.goodsSpec});

  CommonSpecValueList.fromJson(Map<String, dynamic> json) {
    goodsId = json['goodsId'];
    commonId = json['commonId'];
    goodsSpec = json['goodsSpec'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['goodsId'] = this.goodsId;
    data['commonId'] = this.commonId;
    data['goodsSpec'] = this.goodsSpec;
    return data;
  }
}
